home *** CD-ROM | disk | FTP | other *** search
/ The Games Machine 76 / XENIATGM66.iso / Indiana Jones / Indiana Jones.exe / RESOURCE / PREVIEW.GOB / cog_riv_splashparticlemed.cog < prev    next >
Text File  |  1999-11-15  |  2KB  |  84 lines

  1. # Jones 3D Cog Script
  2. #
  3. # RIV_splashparticlemed.cog
  4. #
  5. # gimme a particle with that splash there, Guido...
  6. #
  7. #
  8. #
  9. # [PAZ] [GGJ] modified per Steve Scholl 7/7/99
  10. #
  11. # (C) 1999 LucasArts Entertainment Co. All Rights Reserved
  12. #========================================================================================
  13.  
  14. symbols
  15.  
  16.  
  17.     message         created
  18.     message            sighted
  19.     message            pulse          
  20.  
  21.     thing            spritething                local
  22.     thing            player                    local
  23.     
  24.     flex            pulsetime                local
  25.     
  26.     template        splashA=spritlemist        local
  27.     
  28.     sound            sound0=gen_waterfall_a.wav    local
  29.  
  30.     
  31. end
  32.  
  33. #........................................................................................
  34.  
  35. code
  36.  
  37. #........................................................................................
  38.  
  39. created:
  40.  
  41.     spritething = GetSenderRef();
  42.     #PlaySoundThing(sound0, spritething, 0.8, 1.0, 10.0, 0x01);
  43.     return;
  44.  
  45. #........................................................................................    
  46.  
  47. sighted:
  48.  
  49.     spritething = GetSenderRef();
  50.  
  51.     pulsetime = RandBetween(1, 4);
  52.     SetThingPulse(spritething, pulsetime);
  53.     
  54.     return;
  55.         
  56. #........................................................................................
  57.  
  58. pulse:
  59.  
  60.     player = GetLocalPlayerThing();   
  61.     spritething = GetSenderRef();
  62.  
  63.     CreateThing(splashA, spritething);
  64.     pulsetime=RandBetween(1, 4);
  65.     
  66.     if (HasLOS(player, spritething) == 1)
  67.         {
  68.         SetThingPulse(spritething, pulsetime);
  69.         return;
  70.         }
  71.         
  72.     else
  73.         {
  74.         SetThingPulse(spritething, 0);
  75.         ClearThingFlags(spritething, 0x100000);
  76.         return;
  77.         }
  78.         
  79.     return;
  80.     
  81. #........................................................................................
  82.  
  83. end
  84.